package com.bestcem.xm.wallet.grpc.client.converter.strategy;

import com.bestcem.xm.common.core.uitls.GrpcDateUtil;
import com.google.protobuf.Timestamp;

import java.util.Date;

/**
 * timestamp类型自定义转换器
 *
 * @author wangyunyun <yunyun.wang@idiaoyan.com>
 * @version v1.0
 * @date 2022/4/1 6:49
 */
public interface TimestampStrategy {

    default Timestamp dateToTimestam(Date value) {
        return GrpcDateUtil.getTimestamp(value);
    }
}
